object DMPharmacy: TDMPharmacy
  OldCreateOrder = False
  Height = 1131
  Width = 988
  object his_pharmacy_location: TUniTable
    TableName = 'his_pharmacy_location'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 56
    Top = 24
  end
  object DShis_pharmacy_location: TUniDataSource
    DataSet = his_pharmacy_location
    Left = 56
    Top = 80
  end
  object his_suppliers: TUniTable
    TableName = 'his_suppliers'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 176
    Top = 24
  end
  object DShis_suppliers: TUniDataSource
    DataSet = his_suppliers
    Left = 176
    Top = 80
  end
  object his_pharmacy_ligne: TUniTable
    TableName = 'his_pharmacy_ligne'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 272
    Top = 24
  end
  object DShis_pharmacy_ligne: TUniDataSource
    DataSet = his_pharmacy_ligne
    Left = 272
    Top = 80
  end
  object his_pharmacy_categories: TUniTable
    TableName = 'his_pharmacy_categories'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 400
    Top = 24
  end
  object DShis_pharmacy_categories: TUniDataSource
    DataSet = his_pharmacy_categories
    Left = 400
    Top = 80
  end
  object his_pharmacy_stock: TUniTable
    TableName = 'his_parmacy_stock'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 528
    Top = 24
  end
  object DShis_parmacy_stock: TUniDataSource
    DataSet = his_pharmacy_stock
    Left = 528
    Top = 80
  end
  object his_pharmacy_stock_sub: TUniTable
    TableName = 'his_pharmacy_stock_sub'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 656
    Top = 24
  end
  object DShis_pharmacy_stock_sub: TUniDataSource
    DataSet = his_pharmacy_stock_sub
    Left = 656
    Top = 80
  end
  object his_pharmacy_stock_transfer: TUniTable
    TableName = 'his_pharmacy_stock_transfer'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 104
    Top = 392
  end
  object DShis_pharmacy_stock_transfer: TUniDataSource
    DataSet = his_pharmacy_stock_transfer
    Left = 104
    Top = 448
  end
  object his_pharma_encouter: TUniTable
    TableName = 'his_pharma_encouter'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 56
    Top = 144
  end
  object DShis_pharma_encouter: TUniDataSource
    DataSet = his_pharma_encouter
    Left = 56
    Top = 200
  end
  object his_pharma_encouter_sub: TUniTable
    TableName = 'his_pharma_encouter_sub'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharma_encouter
    MasterFields = 'pharma_encounter_id'
    DetailFields = 'pharma_encounter_id'
    Active = True
    Left = 200
    Top = 144
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharma_encounter_id'
        ParamType = ptInput
        Value = 1
      end>
  end
  object DShis_pharma_encouter_sub: TUniDataSource
    DataSet = his_pharma_encouter_sub
    Left = 200
    Top = 200
  end
  object his_pharmacy_stock_sub_q: TUniQuery
    Connection = FConnection.UniConnection1
    SQL.Strings = (
      'SELECT * FROM his_pharmacy_stock_sub where pharma_id = :a')
    Active = True
    Left = 544
    Top = 272
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'a'
        Value = nil
      end>
  end
  object DShis_pharmacy_stock_sub_q: TUniDataSource
    DataSet = his_pharmacy_stock_sub_q
    Left = 544
    Top = 328
  end
  object his_pharmacy_stock_transfer_request: TUniTable
    TableName = 'his_pharmacy_stock_transfer_request'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 104
    Top = 512
  end
  object DShis_pharmacy_stock_transfer_request: TUniDataSource
    DataSet = his_pharmacy_stock_transfer_request
    Left = 104
    Top = 568
  end
  object his_pharmacy_stock_pharmacy_stock_sub: TUniTable
    TableName = 'his_pharmacy_stock_pharmacy_stock_sub'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 104
    Top = 272
  end
  object DShis_pharmacy_stock_pharmacy_stock_sub: TUniDataSource
    DataSet = his_pharmacy_stock_pharmacy_stock_sub
    Left = 104
    Top = 328
  end
  object his_pharmacy_stock_pharmacy_stock_sub_q: TUniQuery
    Connection = FConnection.UniConnection1
    SQL.Strings = (
      
        'SELECT * FROM his_pharmacy_stock_pharmacy_stock_sub where parmac' +
        'y_stock_id = :a')
    Active = True
    Left = 336
    Top = 272
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'a'
        Value = nil
      end>
  end
  object DShis_pharmacy_stock_pharmacy_stock_sub_q: TUniDataSource
    DataSet = his_pharmacy_stock_pharmacy_stock_sub_q
    Left = 336
    Top = 328
  end
  object DSvirtual_pharmacy_encounter_sub: TUniDataSource
    DataSet = virtual_pharmacy_encounter_sub
    Left = 368
    Top = 200
  end
  object virtual_pharmacy_encounter_sub: TVirtualTable
    Active = True
    FieldDefs = <
      item
        Name = 'pricing_id'
        DataType = ftInteger
      end
      item
        Name = 'parmacy_stock_id'
        DataType = ftInteger
      end
      item
        Name = 'name1'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 45
      end
      item
        Name = 'dept_id'
        DataType = ftInteger
      end
      item
        Name = 'sell_price'
        DataType = ftFloat
      end
      item
        Name = 'expiry_date'
        DataType = ftDate
      end
      item
        Name = 'total_unit_qty'
        DataType = ftFloat
      end
      item
        Name = 'qty_in_stock'
        DataType = ftFloat
      end
      item
        Name = 'add'
        DataType = ftString
        Size = 20
      end
      item
        Name = 'qty'
        DataType = ftString
        Size = 20
      end>
    Left = 368
    Top = 144
    Data = {
      03000A000A0070726963696E675F6964030000000000000010007061726D6163
      795F73746F636B5F6964030000000000000005006E616D653118002D00000000
      000700646570745F696403000000000000000A0073656C6C5F70726963650600
      0000000000000B006578706972795F6461746509000000000000000E00746F74
      616C5F756E69745F71747906000000000000000C007174795F696E5F73746F63
      6B06000000000000000300616464010014000000000003007174790100140000
      000000000000000000}
  end
  object his_pharmacy_supplier_invoice: TUniTable
    TableName = 'his_pharmacy_supplier_invoice'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 544
    Top = 144
  end
  object DShis_pharmacy_supplier_invoice: TUniDataSource
    DataSet = his_pharmacy_supplier_invoice
    Left = 544
    Top = 200
  end
  object DShis_pharmacy_invoice_invoice_detail: TUniDataSource
    DataSet = his_pharmacy_invoice_invoice_detail
    Left = 728
    Top = 200
  end
  object his_pharmacy_invoice_invoice_detail: TUniQuery
    Connection = FConnection.UniConnection1
    SQL.Strings = (
      
        'SELECT * FROM his_pharmacy_invoice_invoice_detail where pharmacy' +
        '_supplier_invoice_id = :a')
    Active = True
    Left = 728
    Top = 144
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'a'
        Value = nil
      end>
  end
  object virtual_pharmacy_stock_transfer_sub: TVirtualTable
    Active = True
    FieldDefs = <
      item
        Name = 'pharmacy_stock_transfer_id'
        DataType = ftInteger
      end
      item
        Name = 'pricing_id'
        DataType = ftInteger
      end
      item
        Name = 'from_dept'
        DataType = ftInteger
      end
      item
        Name = 'expiry'
        DataType = ftDate
      end
      item
        Name = 'qty'
        DataType = ftFloat
      end
      item
        Name = 'qtyInStock'
        DataType = ftFloat
      end
      item
        Name = 'qtyToTransfer'
        DataType = ftFloat
      end
      item
        Name = 'add'
        DataType = ftBoolean
      end>
    Left = 488
    Top = 392
    Data = {
      030008001A00706861726D6163795F73746F636B5F7472616E736665725F6964
      03000000000000000A0070726963696E675F6964030000000000000009006672
      6F6D5F6465707403000000000000000600657870697279090000000000000003
      0071747906000000000000000A00717479496E53746F636B0600000000000000
      0D00717479546F5472616E736665720600000000000000030061646405000000
      00000000000000000000}
    object virtual_pharmacy_stock_transfer_subpharmacy_stock_transfer_id: TIntegerField
      FieldName = 'pharmacy_stock_transfer_id'
    end
    object virtual_pharmacy_stock_transfer_subpricing_id: TIntegerField
      FieldName = 'pricing_id'
    end
    object virtual_pharmacy_stock_transfer_subfrom_dept: TIntegerField
      FieldName = 'from_dept'
    end
    object virtual_pharmacy_stock_transfer_subexpiry: TDateField
      FieldName = 'expiry'
    end
    object virtual_pharmacy_stock_transfer_subqty2: TFloatField
      FieldName = 'qty'
    end
    object virtual_pharmacy_stock_transfer_subqtyInStock: TFloatField
      FieldName = 'qtyInStock'
    end
    object virtual_pharmacy_stock_transfer_subqtyToTransfer: TFloatField
      FieldName = 'qtyToTransfer'
    end
    object virtual_pharmacy_stock_transfer_subadd: TBooleanField
      FieldName = 'add'
    end
  end
  object DSvirtual_pharmacy_stock_transfer_sub: TUniDataSource
    DataSet = virtual_pharmacy_stock_transfer_sub
    Left = 488
    Top = 448
  end
  object his_pharmacy_stock_transfer_sub: TUniTable
    TableName = 'his_pharmacy_stock_transfer_sub'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_stock_transfer
    MasterFields = 'pharmacy_stock_transfer_id'
    DetailFields = 'pharmacy_stock_transfer_id'
    Active = True
    Left = 280
    Top = 392
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharmacy_stock_transfer_id'
        ParamType = ptInput
        Value = 1
      end>
  end
  object DShis_pharmacy_stock_transfer_sub: TUniDataSource
    DataSet = his_pharmacy_stock_transfer_sub
    Left = 280
    Top = 448
  end
  object his_all_pharmacy_stock_items: TUniTable
    TableName = 'his_all_pharmacy_stock_items'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 680
    Top = 392
  end
  object DShis_all_pharmacy_stock_items: TUniDataSource
    DataSet = his_all_pharmacy_stock_items
    Left = 680
    Top = 448
  end
  object his_pharmacy_stock_transfer_request_sub: TUniTable
    TableName = 'his_pharmacy_stock_transfer_request_sub'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_stock_transfer_request
    MasterFields = 'pharmacy_stock_transfer_id'
    DetailFields = 'pharmacy_stock_transfer_request_id'
    Active = True
    Left = 328
    Top = 512
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharmacy_stock_transfer_id'
        ParamType = ptInput
        Value = nil
      end>
  end
  object DShis_pharmacy_stock_transfer_request_sub: TUniDataSource
    DataSet = his_pharmacy_stock_transfer_request_sub
    Left = 328
    Top = 568
  end
  object virtual_pharmacy_stock_transfer_request_sub: TVirtualTable
    Active = True
    FieldDefs = <
      item
        Name = 'pharmacy_stock_transfer_id'
        DataType = ftInteger
      end
      item
        Name = 'pricing_id'
        DataType = ftInteger
      end
      item
        Name = 'from_dept'
        DataType = ftInteger
      end
      item
        Name = 'expiry'
        DataType = ftDate
      end
      item
        Name = 'qty'
        DataType = ftFloat
      end
      item
        Name = 'qtyInStock'
        DataType = ftFloat
      end
      item
        Name = 'qtyToTransfer'
        DataType = ftFloat
      end
      item
        Name = 'add'
        DataType = ftBoolean
      end>
    Left = 568
    Top = 512
    Data = {
      030008001A00706861726D6163795F73746F636B5F7472616E736665725F6964
      03000000000000000A0070726963696E675F6964030000000000000009006672
      6F6D5F6465707403000000000000000600657870697279090000000000000003
      0071747906000000000000000A00717479496E53746F636B0600000000000000
      0D00717479546F5472616E736665720600000000000000030061646405000000
      00000000000000000000}
    object IntegerField1: TIntegerField
      FieldName = 'pharmacy_stock_transfer_id'
    end
    object IntegerField2: TIntegerField
      FieldName = 'pricing_id'
    end
    object IntegerField3: TIntegerField
      FieldName = 'from_dept'
    end
    object DateField1: TDateField
      FieldName = 'expiry'
    end
    object FloatField1: TFloatField
      FieldName = 'qty'
    end
    object FloatField2: TFloatField
      FieldName = 'qtyInStock'
    end
    object FloatField3: TFloatField
      FieldName = 'qtyToTransfer'
    end
    object BooleanField1: TBooleanField
      FieldName = 'add'
    end
  end
  object DSvirtual_pharmacy_stock_transfer_request_sub: TUniDataSource
    DataSet = virtual_pharmacy_stock_transfer_request_sub
    Left = 568
    Top = 568
  end
  object his_pharmacy_return: TUniTable
    TableName = 'his_pharmacy_return'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 104
    Top = 632
  end
  object DShis_pharmacy_return: TUniDataSource
    DataSet = his_pharmacy_return
    Left = 104
    Top = 688
  end
  object his_pharmacy_return_sub: TUniTable
    TableName = 'his_pharmacy_return_sub'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_return
    MasterFields = 'pharma_return_id'
    DetailFields = 'pharma_return_id'
    Active = True
    Left = 240
    Top = 632
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharma_return_id'
        ParamType = ptInput
        Value = nil
      end>
  end
  object DShis_pharmacy_return_sub: TUniDataSource
    DataSet = his_pharmacy_return_sub
    Left = 240
    Top = 688
  end
  object DSvirtual_pharmacy_return_sub: TUniDataSource
    DataSet = virtual_pharmacy_return_sub
    Left = 400
    Top = 688
  end
  object virtual_pharmacy_return_sub: TVirtualTable
    Active = True
    FieldDefs = <
      item
        Name = 'pharma_return_id'
        DataType = ftInteger
      end
      item
        Name = 'pricing_id'
        DataType = ftInteger
      end
      item
        Name = 'returned_qty'
        DataType = ftInteger
      end
      item
        Name = 'add'
        DataType = ftSmallint
      end
      item
        Name = 'pharmacy_stock_id'
        DataType = ftInteger
      end
      item
        Name = 'current_qty'
        DataType = ftInteger
      end
      item
        Name = 'qty_in_stock'
        DataType = ftInteger
      end>
    Left = 400
    Top = 632
    Data = {
      030007001000706861726D615F72657475726E5F696403000000000000000A00
      70726963696E675F696403000000000000000C0072657475726E65645F717479
      0300000000000000030061646402000000000000001100706861726D6163795F
      73746F636B5F696403000000000000000B0063757272656E745F717479030000
      00000000000C007174795F696E5F73746F636B03000000000000000000000000
      00}
  end
  object his_pharmacy_item_naming: TUniTable
    TableName = 'his_pharmacy_item_naming'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 800
    Top = 24
  end
  object DShis_pharmacy_item_naming: TUniDataSource
    DataSet = his_pharmacy_item_naming
    Left = 800
    Top = 80
  end
  object his_pharmacy_stock_count: TUniTable
    TableName = 'his_pharmacy_stock_count'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 696
    Top = 272
  end
  object DShis_pharmacy_stock_count: TUniDataSource
    DataSet = his_pharmacy_stock_count
    Left = 696
    Top = 328
  end
  object his_pharmacy_order: TUniTable
    TableName = 'his_pharmacy_order'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 560
    Top = 632
  end
  object DShis_pharmacy_order: TUniDataSource
    DataSet = his_pharmacy_order
    Left = 560
    Top = 688
  end
  object his_pharmacy_order_sub: TUniTable
    TableName = 'his_pharmacy_order_sub'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_order
    MasterFields = 'pharmacy_order_id'
    DetailFields = 'pharmacy_order_id'
    Active = True
    Left = 704
    Top = 632
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharmacy_order_id'
        ParamType = ptInput
        Value = nil
      end>
  end
  object DShis_pharmacy_order_sub: TUniDataSource
    DataSet = his_pharmacy_order_sub
    Left = 704
    Top = 688
  end
  object his_pharmacy_department: TUniTable
    TableName = 'his_pharmacy_department'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 768
    Top = 512
  end
  object DShis_pharmacy_department: TUniDataSource
    DataSet = his_pharmacy_department
    Left = 768
    Top = 568
  end
  object DShis_pharmacy_stock_pharmacy_stock_sub_for_return: TUniDataSource
    DataSet = his_pharmacy_stock_pharmacy_stock_sub_for_return
    Left = 136
    Top = 816
  end
  object his_pharmacy_stock_pharmacy_stock_sub_for_return: TUniTable
    TableName = 'his_pharmacy_stock_pharmacy_stock_sub'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_supplier_invoice
    MasterFields = 'pharmacy_supplier_invoice_id'
    DetailFields = 'supp_invoice_id'
    Active = True
    Left = 136
    Top = 760
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharmacy_supplier_invoice_id'
        ParamType = ptInput
        Value = 1
      end>
  end
  object his_pharmacy_stock_pharmacy_stock_sub_q_for_return: TUniQuery
    Connection = FConnection.UniConnection1
    SQL.Strings = (
      
        'SELECT * FROM his_pharmacy_stock_pharmacy_stock_sub where parmac' +
        'y_stock_id = :a and supp_invoice_id = :b')
    Active = True
    Left = 432
    Top = 760
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'a'
        Value = nil
      end
      item
        DataType = ftUnknown
        Name = 'b'
        Value = nil
      end>
  end
  object DShis_pharmacy_stock_pharmacy_stock_sub_q_for_return: TUniDataSource
    DataSet = his_pharmacy_stock_pharmacy_stock_sub_q_for_return
    Left = 432
    Top = 816
  end
  object his_pharmacy_stock_pharmacy_stock_sub_trans: TUniQuery
    Connection = FConnection.UniConnection1
    SQL.Strings = (
      
        'SELECT * FROM his_pharmacy_stock_pharmacy_stock_sub where parmac' +
        'y_stock_id = :a and dept_id=1')
    Active = True
    Left = 712
    Top = 760
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'a'
        Value = nil
      end>
  end
  object DShis_pharmacy_stock_pharmacy_stock_sub_trans: TUniDataSource
    DataSet = his_pharmacy_stock_pharmacy_stock_sub_trans
    Left = 712
    Top = 816
  end
  object his_pharmacy_supplier_invoice_report: TUniQuery
    Connection = FConnection.UniConnection1
    SQL.Strings = (
      
        'Select * from his_pharmacy_supplier_invoice_report where pharmac' +
        'y_supplier_invoice_id = :a')
    Active = True
    Left = 136
    Top = 872
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'a'
        Value = nil
      end>
  end
  object DShis_pharmacy_supplier_invoice_report: TUniDataSource
    DataSet = his_pharmacy_supplier_invoice_report
    Left = 136
    Top = 928
  end
  object his_pharmacy_stock_return_sub_items: TUniQuery
    Connection = FConnection.UniConnection1
    SQL.Strings = (
      
        'SELECT * FROM his_pharmacy_stock_pharmacy_stock_sub where supp_i' +
        'nvoice_id = :b')
    Active = True
    Left = 432
    Top = 872
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'b'
        Value = nil
      end>
  end
  object DShis_pharmacy_stock_return_sub_items: TUniDataSource
    DataSet = his_pharmacy_stock_return_sub_items
    Left = 432
    Top = 928
  end
  object his_pharmacy_return_report: TUniTable
    TableName = 'his_pharmacy_return_report'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_return
    MasterFields = 'pharma_return_id'
    DetailFields = 'Return ID'
    Active = True
    Left = 648
    Top = 872
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharma_return_id'
        ParamType = ptInput
        Value = nil
      end>
  end
  object DShis_pharmacy_return_report: TUniDataSource
    DataSet = his_pharmacy_return_report
    Left = 648
    Top = 928
  end
  object his_pharmacy_transfer_report: TUniTable
    TableName = 'his_pharmacy_transfer_report'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_stock_transfer
    MasterFields = 'pharmacy_stock_transfer_id'
    DetailFields = 'Transfer ID'
    Active = True
    Left = 832
    Top = 872
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharmacy_stock_transfer_id'
        ParamType = ptInput
        Value = 1
      end>
  end
  object DShis_pharmacy_transfer_report: TUniDataSource
    DataSet = his_pharmacy_transfer_report
    Left = 832
    Top = 928
  end
  object his_pharmacy_transfer_request_report: TUniTable
    TableName = 'his_pharmacy_transfer_request_report'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_stock_transfer_request
    MasterFields = 'pharmacy_stock_transfer_id'
    DetailFields = 'Transfer ID'
    Active = True
    Left = 136
    Top = 984
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharmacy_stock_transfer_id'
        ParamType = ptInput
        Value = nil
      end>
  end
  object DShis_pharmacy_transfer_request_report: TUniDataSource
    DataSet = his_pharmacy_transfer_request_report
    Left = 136
    Top = 1040
  end
  object his_pharmacy_order_report: TUniTable
    TableName = 'his_pharmacy_order_report'
    Connection = FConnection.UniConnection1
    MasterSource = DShis_pharmacy_order
    MasterFields = 'pharmacy_order_id'
    DetailFields = 'pharmacy_order_id'
    Active = True
    Left = 376
    Top = 984
    ParamData = <
      item
        DataType = ftInteger
        Name = 'pharmacy_order_id'
        ParamType = ptInput
        Value = nil
      end>
  end
  object DShis_pharmacy_order_report: TUniDataSource
    DataSet = his_pharmacy_order_report
    Left = 376
    Top = 1040
  end
  object his_pharmacy_sub_cat: TUniTable
    TableName = 'his_pharmacy_sub_cat'
    Connection = FConnection.UniConnection1
    Active = True
    Left = 888
    Top = 144
  end
  object DShis_pharmacy_sub_cat: TUniDataSource
    DataSet = his_pharmacy_sub_cat
    Left = 888
    Top = 200
  end
end
